The present invention relates to a method and apparatus for welding two pipes along their line of penetration wherein, after cutting the line of penetration of the secondary pipe and taking into consideration the welding bevel (and, if necessary, after cutting the line of penetration of the primary pipe), both pipes are attached to one another and welded together.